package com.zhuss.product.preline;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Component;

import com.zhuss.bean.bo.product.line.SearchLineBo;
import com.zhuss.bean.bo.product.preline.DetailPrelineSignBo;
import com.zhuss.bean.bo.product.preline.SearchPrelineSignBo;
import com.zhuss.common.ReadService;
import com.zhuss.exception.DzcxException;
import com.zhuss.product.processor.PrelineSignRead;

/**
 * @description: 招募报名查询Service
 * @author: zhushanshuo
 * @create: Wed Jan 06 16:26:20 CST 2021
 **/
@Component("prelineSignReadService")
public class PrelineSignReadService implements ReadService<Object, Object> {

	@Autowired
	@Qualifier("prelineSignRead")
	private PrelineSignRead prelineSignRead;

	/**
	 * 详情
	 */
	@Override
	public Object detail(Object param) throws DzcxException {
		DetailPrelineSignBo bo = (DetailPrelineSignBo) param;
		Long prelineId = bo.getPrelineId();
		Object vo = prelineSignRead.detail(prelineId);
		return vo;
	}

	/**
	 * 列表
	 */
	@Override
	public Object list(Object param) {
		SearchPrelineSignBo bo = (SearchPrelineSignBo) param;
		Object result = prelineSignRead.list(bo);
		return result;
	}

	public Object mySignList(SearchPrelineSignBo bo) throws DzcxException {
		return prelineSignRead.mySignList(bo);
	}
	
	public List<Long> listByUser(SearchLineBo bo) throws DzcxException {
		List<Long> lineIdList = prelineSignRead.listByUser(bo);
		return lineIdList;
	}

}

